/*--------------------------------------------------------------
19. Card
----------------------------------------------------------------*/
.td_card.td_style_1 {
  border: 1px solid #ebeced;
  padding: 30px;
  @media (max-width: 1400px) {
    padding: 25px;
  }
  @media (max-width: 575px) {
    padding: 15px 15px 25px 15px;
  }
  .td_card_location {
    display: flex;
    align-items: center;
    gap: 10px;
  }
  .td_card_thumb {
    position: relative;
    overflow: hidden;
    box-shadow: 2px 2px 500px 0px rgba(0, 0, 27, 0.3) inset;
    &::before,
    &::after {
      content: '';
      position: absolute;
      height: 100%;
      width: 100%;
      left: 0;
      top: 0;
      transition: all 0.4s ease;
    }
    &::before {
      z-index: 1;
      opacity: 0;
      background-color: var(--accent-color);
    }
    &::after {
      z-index: 2;
      box-shadow: 2px 2px 500px 0px rgba(0, 0, 27, 0.1) inset;
    }
    i {
      position: absolute;
      top: 50%;
      left: 50%;
      transform: translate(-50%, -50%) scale(0) rotate(-120deg);
      color: #fff;
      font-size: 50px;
      z-index: 3;
      opacity: 0;
      transition: all 0.5s ease;
    }
    &:hover {
      &::before {
        opacity: 0.3;
      }
      i {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1) rotate(0deg);
        &:hover {
          opacity: 0.8;
        }
      }
    }
    .td_card_location {
      position: absolute;
      right: 20px;
      bottom: 20px;
      z-index: 2;
    }
  }
  .td_card_meta {
    display: flex;
    @media (max-width: 575px) {
      flex-wrap: wrap;
      gap: 6px 0;
    }
    li {
      display: flex;
      align-items: center;
      gap: 8px;
      flex: 1;
      position: relative;
      @media (max-width: 575px) {
        flex: none;
        svg {
          width: 20px;
        }
      }
      &:last-child {
        justify-content: flex-end;
      }
      &:not(:last-child) {
        &::after {
          content: '';
          position: absolute;
          top: 0;
          right: 0;
          height: 100%;
          width: 1px;
          background-color: var(--accent-color);
          opacity: 0.5;
        }
        @media (max-width: 575px) {
          margin-right: 12px;
          padding-right: 12px;
        }
      }
    }
  }
  .td_card_title {
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    a {
      background-repeat: no-repeat;
      background-image: linear-gradient(
        90deg,
        currentColor 0,
        currentColor 100%
      );
      transition: background-size 0.5s cubic-bezier(0.49, 0.49, 0.08, 1),
        color 0.27s ease-out;
      background-position: 100% calc(100% - 0px);
      background-size: 0 2px;
      &:hover {
        background-size: 100% 2px;
        background-position: 0 calc(100% - 0px);
      }
    }
  }
  &.td_type_1,
  &.td_type_2 {
    border: none;
    display: flex;
    gap: 30px;
    padding: 0;
    @media (max-width: 1400px) {
      gap: 15px;
    }
    @media (max-width: 575px) {
      flex-direction: column;
      width: 100%;
      .td_mb_20 {
        margin-bottom: 10px;
      }
    }
    .td_card_thumb {
      flex: none;
      width: 240px;
      height: 235px;
      border-radius: 5px;
      @media (max-width: 1400px) {
        height: 215px;
        width: 230px;
      }
      @media (max-width: 1199px) {
        height: 207px;
        width: 190px;
      }
      @media (max-width: 991px) {
        height: 200px;
        width: 220px;
      }
      @media (max-width: 575px) {
        height: 235px;
        width: 100%;
      }
      img {
        height: 100%;
        width: 100%;
        object-fit: cover;
      }
      i {
        font-size: 36px;
      }
    }
    .td_card_meta {
      li {
        flex: none;
        &:not(:last-child) {
          padding-right: 30px;
          margin-right: 30px;
          @media (max-width: 1199px) {
            padding-right: 12px;
            margin-right: 12px;
          }
        }
        svg {
          height: 18px;
          width: 18px;
        }
      }
    }
    .td_card_info {
      display: flex;
      align-items: center;
      border-style: solid;
      border-width: 1px 0 1px 0;
      border-color: #ebeced;
      @media (max-width: 575px) {
        border: none;
      }
    }
    .td_card_title {
      a {
        background-position: 100% calc(100% - 0px);
        background-size: 0 1px;
        &:hover {
          background-size: 100% 1px;
          background-position: 0 calc(100% - 0px);
        }
      }
    }
  }
  &.td_type_2 {
    padding: 30px 40px;
    border-radius: 50px;
    padding-right: 90px;
    gap: 40px;
    @media (max-width: 1400px) {
      padding: 25px;
      padding-right: 25px;
      gap: 25px;
    }
    @media (max-width: 991px) {
      flex-direction: column;
    }
    .td_card_thumb {
      width: 346px;
      height: 291px;
      border-radius: 50px;
      @media (max-width: 1400px) {
        height: 320px;
      }
      @media (max-width: 1199px) {
        width: 290px;
      }
      @media (max-width: 991px) {
        width: 100%;
      }
      @media (max-width: 575px) {
        height: 280px;
      }
    }
    .td_card_info {
      border: none;
    }
    .td_card_meta {
      @media (max-width: 1400px) {
        flex-wrap: wrap;
        gap: 5px 0;
      }
      li {
        &:not(:last-child) {
          padding-right: 40px;
          margin-right: 40px;
          @media (max-width: 1400px) {
            padding-right: 20px;
            margin-right: 20px;
          }
          @media (max-width: 1199px) {
            padding-right: 12px;
            margin-right: 12px;
          }
        }
      }
    }
    @media (max-width: 1199px) {
      .td_mb_30 {
        margin-bottom: 16px;
      }
      .td_mb_25 {
        margin-bottom: 15px;
      }
      .td_mb_40 {
        margin-bottom: 20px;
      }
    }
  }
  &.td_type_3 {
    border: none;
    padding: 0;
    margin-right: 50px;
    @media (max-width: 1400px) {
      margin-right: 0px;
    }
    .td_card_title {
      text-overflow: initial;
      display: block;
      -webkit-line-clamp: initial;
      -webkit-box-orient: initial;
      overflow: initial;
    }
    .td_card_meta.td_type_2 {
      justify-content: flex-start;
      flex-wrap: wrap;
      gap: 10px 50px;
      li {
        flex: none;
        &::after {
          display: none;
        }
      }
    }
    .td_map {
      height: 365px;
    }
  }
}

.td_card.td_style_2 {
  .td_card_info {
    display: flex;
    justify-content: space-between;
    padding: 13px 20px 0px 20px;
    border-radius: 0 0 10px 10px;
    background-color: var(--accent-color);
    gap: 0 10px;
    @media (max-width: 1199px) {
      padding: 13px 15px 0px 15px;
    }
  }
  .td_card_thumb {
    border-radius: 10px 10px 0 0;
    overflow: hidden;
    img {
      border-radius: inherit;
      transition: all 0.7s ease;
    }
    &:hover {
      img {
        transform: scale(1.04);
        transform-origin: top;
      }
    }
  }
  .td_card_title {
    a {
      &:hover {
        color: #fff;
        opacity: 0.75;
      }
    }
  }
  .td_card_btn {
    flex: none;
    width: 23px;
    height: 24px;
    position: relative;
    overflow: hidden;
    display: inline-flex;
    svg {
      transition: all 0.4s ease;
      &:nth-child(2) {
        position: absolute;
        left: -23px;
        bottom: -24px;
      }
    }
    &:hover {
      svg {
        &:first-child {
          transform: translate(23px, -24px);
        }
        &:nth-child(2) {
          position: absolute;
          left: 0px;
          bottom: 0px;
        }
      }
    }
  }
}

.td_card.td_style_3 {
  overflow: hidden;
  position: relative;
  box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.05);
  .td_card_label {
    position: absolute;
    left: 20px;
    top: 20px;
    z-index: 2;
    padding: 4px 10px;
    border-radius: 6px;
  }
  .td_card_title,
  .td_card_subtitle {
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }

  .td_card_meta {
    display: flex;
    margin-bottom: 20px;
    li {
      display: flex;
      gap: 6px;
      align-items: center;
      position: relative;
      &:not(:last-child) {
        padding-right: 30px;
        margin-right: 30px;
        @media (max-width: 1400px) {
          padding-right: 20px;
          margin-right: 20px;
        }
        @media (max-width: 1199px) {
          padding-right: 12px;
          margin-right: 12px;
        }
        &::before {
          content: '';
          position: absolute;
          height: 20px;
          width: 1px;
          background-color: var(--accent-color);
          right: 0;
          top: 50%;
          margin-top: -10px;
        }
      }
    }
    @media (max-width: 1199px) {
      font-size: 16px;
      img {
        width: 20px;
      }
    }
  }
  .td_card_category {
    padding: 4px 10px;
    display: inline-flex;
    position: relative;
    box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.05);
    span {
      position: relative;
      z-index: 2;
    }
    &::before {
      content: '';
      position: absolute;
      height: 100%;
      width: 100%;
      left: 0;
      top: 0;
      background-color: var(--accent-color);
      opacity: 0.12;
    }
  }
  .td_card_info {
    padding: 30px;
    position: relative;
    z-index: 1;
    transition: all 0.4s ease;
    @media (max-width: 1400px) {
      padding: 25px;
    }
    @media (max-width: 1199px) {
      padding: 18px 20px 22px 20px;
    }
  }
  .td_card_review {
    display: flex;
    align-items: center;
    gap: 10px;
  }
  .td_card_btn {
    padding-top: 25px;
    margin-bottom: -75px;
    transition: all 0.4s ease;
  }
  .td_card_info_in {
    overflow: hidden;
  }
  .td_card_thumb {
    overflow: hidden;
    display: block;
    position: relative;
    img {
      width: 100%;
      transition: all 0.8s ease;
    }
    &:hover {
      img {
        transform: scale(1.04);
      }
    }
  }
  .td_card_lable {
    position: absolute;
    z-index: 1;
    top: 25px;
    left: 24px;
    display: inline-flex;
    padding: 9px 15px;
  }
  &:hover {
    .td_card_info {
      margin-top: -75px;
    }
    .td_card_btn {
      margin-bottom: 0px;
    }
  }
  &.td_type_1 {
    padding: 20px;
    background-color: #fff;
    border-radius: 50px;
    clip-path: inset(0 round 50px 50px 50px 50px);
    position: relative;
    &::before {
      content: '';
      position: absolute;
      left: -4px;
      top: -4px;
      right: -4px;
      bottom: -4px;
      border: 5px dashed #6440fb;
      border-radius: 54px;
    }
    > * {
      position: relative;
      z-index: 2;
    }
    .td_card_thumb {
      border-radius: 50px;
      overflow: hidden;
      height: 265px;
      img {
        height: 100%;
        width: 100%;
        object-fit: cover;
      }
    }
    .td_card_category {
      border-radius: 50px;
      background: linear-gradient(90deg, #fff0d4 0.07%, #d6fff7 95.86%);
      box-shadow: 0px 4px 4px 0px rgba(0, 0, 0, 0.05);
      &::before {
        border-radius: 50px;
      }
    }
    .td_card_meta {
      margin: 0;
    }
    .td_card_info {
      padding: 30px 10px 10px 10px;
      @media (max-width: 1199px) {
        padding: 25px 0px 10px 0px;
      }
    }
    .td_btn.td_style_1 {
      .td_btn_in {
        padding: 10px 25px;
      }
    }
    &:hover {
      .td_card_thumb {
        height: 196px;
        margin-bottom: 69px;
      }
    }
  }
  &.td_type_2 {
    box-shadow: none;
    .td_card_info {
      border: 2px solid var(--border-color);
      border-top: 0;
    }
    .td_card_meta {
      margin-bottom: 15px;
    }
    &:hover {
      .td_card_info {
        margin-top: 0;
      }
    }
  }
  &.td_type_3 {
    box-shadow: none;
    .td_card_thumb {
      img {
        width: 100%;
      }
    }
    .td_card_info_in {
      overflow: initial;
    }
    .td_card_info {
      padding-top: 24px;
    }
    .td_card_meta {
      justify-content: space-around;
      gap: 0 20px;
      padding: 12px 30px;
      margin-bottom: 0;

      li {
        &:not(:last-child) {
          padding-right: 0;
          margin-right: 0;
        }
        &::before {
          display: none;
        }
      }
    }
    .td_card_enroll {
      display: flex;
      align-items: center;
      gap: 14px;
      flex-wrap: wrap;
    }
    .td_btn.td_style_1 {
      .td_btn_in {
        padding: 8px 16px;
      }
    }
    .td_rating {
      transform: scale(0.8);
      margin: 0 -10px;
    }
    .td_card_title {
      a {
        &:hover {
          color: #fff;
          opacity: 0.8;
        }
      }
    }
    .td_btn.td_style_1.td_with_shadow_2 {
      box-shadow: 4px 4px 0px 0px var(--heading-color);
      &:hover {
        box-shadow: 4px -4px 0px 0px var(--heading-color);
      }
    }
    &:hover {
      .td_card_info {
        margin-top: 0;
      }
    }
  }
}

.td_card.td_style_4 {
  background-color: var(--accent-color);
  border-radius: 50px;
  gap: 15px 45px;
  display: flex;
  padding: 40px;
  box-shadow: 2px 2px 500px 0px rgba(0, 0, 27, 0.1) inset;
  position: relative;
  overflow: hidden;
  @media (max-width: 1400px) {
    flex-direction: column-reverse;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 40px 20px;
  }
  h3 {
    span {
      display: inline-block;
      background-color: #fff;
      color: var(--accent-color);
      padding: 0 10px;
    }
  }
  .td_card_thumb {
    flex: none;
    width: 250px;
    height: 250px;
    border-radius: 50%;
    overflow: hidden;
    flex: none;
    img {
      height: 100%;
      width: 100%;
      object-fit: cover;
    }
  }
  .td_btn.td_style_1.td_type_3 {
    &.td_with_shadow {
      &:after {
        background-color: rgb(40 11 183 / 80%);
      }
    }
    &:hover {
      .td_btn_in {
        border-color: #fff;
        color: var(--accent-color);
        &::before {
          background-color: #fff;
        }
      }
    }
  }
  .td_card_1 {
    position: absolute;
    right: -30px;
    top: -60px;
  }
  .td_card_2 {
    position: absolute;
    right: -30px;
    bottom: -60px;
  }
}
.td_card.td_style_5 {
  display: flex;
  align-items: center;
  gap: 20px;
  @media (max-width: 1400px) {
    gap: 15px;
  }
  @media (max-width: 767px) {
    flex-direction: column;
    gap: 20px;
  }
  .td_card_title {
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .td_card_label {
    position: absolute;
    left: 20px;
    top: 20px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 15px;
    border-radius: 30px;
    z-index: 2;
    img {
      width: 14px;
      height: 14px;
    }
  }
  .td_card_thumb {
    border-radius: 10px;
    padding: 12px;
    flex: none;
    width: 300px;
    height: 242px;
    position: relative;
    clip-path: inset(0 round 10px 10px 10px 10px);
    @media (max-width: 1400px) {
      padding: 6px;
      width: 250px;
    }
    @media (max-width: 1199px) {
      width: 300px;
      padding: 12px;
    }
    @media (max-width: 767px) {
      width: 100%;
      height: 260px;
    }
    &:before {
      content: '';
      position: absolute;
      left: -3px;
      top: -3px;
      right: -3px;
      bottom: -3px;
      border: 4px dashed var(--border-color);
      border-radius: 13px;
    }
    .td_card_thumb_in {
      height: 100%;
      width: 100%;
      > img {
        height: 100%;
        width: 100%;
        object-fit: cover;
      }
    }
    &:hover {
      .td_card_thumb_in {
        > img {
          transform: scale(1.05);
        }
      }
    }
  }
  .td_card_thumb_in {
    display: block;
    overflow: hidden;
    position: relative;
    z-index: 2;
    > img {
      transition: all 0.5s ease;
    }
  }
  .td_card_content {
    @media (max-width: 767px) {
      width: 100%;
    }
  }
  .td_card_meta {
    display: flex;
    margin-bottom: 20px;
    li {
      display: flex;
      gap: 6px;
      align-items: center;
      position: relative;
      &:not(:last-child) {
        padding-right: 25px;
        margin-right: 25px;
        &::before {
          content: '';
          position: absolute;
          height: 20px;
          width: 1px;
          background-color: var(--accent-color);
          right: 0;
          top: 50%;
          margin-top: -10px;
        }
      }
      img {
        width: 20px;
        height: 20px;
      }
    }
  }
  .td_btn.td_style_1.td_type_3 {
    .td_btn_in {
      padding: 8px 16px;
    }
  }
  .td_card_btns_wrap {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 5px 10px;
  }
  .td_card_price {
    display: inline-flex;
    padding: 5px 10px;
    min-width: 62px;
    justify-content: center;
    text-align: center;
    border-radius: 30px;
  }
  .td_card_price_wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
  }
  .td_card_review {
    display: flex;
    align-items: center;
  }
  .td_rating {
    transform: scale(0.8);
    margin-left: -12px;
    margin-right: -5px;
  }
  &.td_type_1 {
    .td_card_thumb {
      padding: 16px;
      border-radius: 50px;
      background-color: #ebeced;
      box-shadow: 4px 4px 0px 0px rgba(0, 0, 0, 0.15);
      border: none;
      clip-path: initial;
      &:before {
        display: none;
      }
    }
    .td_card_thumb_in {
      border-radius: 50px;
      overflow: hidden;
    }
    &:hover {
      .td_card_thumb {
        background-color: var(--accent-color);
        box-shadow: initial;
      }
    }
  }
  &.td_type_2 {
    .td_card_label {
      position: initial;
      &:hover {
        color: #fff;
        opacity: 0.9;
      }
    }
    .td_card_flag {
      height: 40px;
      width: 40px;
      border-radius: 50%;
      object-fit: cover;
      position: absolute;
      top: 24px;
      left: 24px;
      z-index: 2;
    }
  }
  &.td_type_3 {
    position: relative;
    &::before {
      content: '';
      position: absolute;
      height: calc(100% + 20px);
      width: calc(100% + 20px);
      left: -10px;
      top: -10px;
      border-radius: 10px;
      border: 1px solid var(--accent-color);
      pointer-events: none;
      z-index: -1;
      opacity: 0;
      transition: all 0.3s ease;
    }
    .td_card_thumb {
      padding: 0;
      border-radius: 0;
      clip-path: initial;
      &:before {
        display: none;
      }
    }
    .td_card_label {
      gap: 5px;
      padding: 5px 10px;
      border-radius: 10px;
    }
    .td_card_price {
      border: 1px solid var(--accent-color);
      border-radius: 10px;
      transition: all 0.4s ease;
    }
    .td_btn.td_style_1.td_type_3 {
      .td_btn_in {
        transition: all 0.4s ease;
      }
    }
    &:hover {
      &::before {
        opacity: 1;
      }
      .td_card_price {
        background-color: var(--accent-color);
        color: #fff;
      }
      .td_btn.td_style_1.td_type_3 {
        .td_btn_in {
          color: #fff;
          border-color: var(--accent-color);
          background-color: var(--accent-color);
          &:before {
            background-color: var(--heading-color);
          }
        }
        &:hover {
          .td_btn_in {
            &:before {
              opacity: 0.25;
            }
          }
        }
      }
    }
  }
}
.td_card.td_style_6 {
  padding: 30px;
  box-shadow: 2px 2px 50px 0px rgba(0, 0, 27, 0.1);
  @media (max-width: 1400px) {
    padding: 25px;
  }
  .td_card_list {
    border-top: 1px solid var(--heading-color);
    li {
      display: flex;
      justify-content: space-between;
      border-bottom: 1px solid var(--heading-color);
      padding: 10px 0;
    }
  }
}
.td_card.td_style_7 {
  border-radius: 10px;
  background-color: #fff;
  padding: 30px;
  box-shadow: 2px 2px 50px 0px rgba(0, 0, 27, 0.1);
  margin: -250px 0 0 25px;
  position: relative;
  z-index: 10;
  @media (max-width: 1400px) {
    margin-left: 0;
  }
  @media (max-width: 1199px) {
    padding: 30px 24px;
  }
  @media (max-width: 991px) {
    margin-top: 0;
  }
  .td_card_list {
    li {
      display: flex;
      justify-content: space-between;
      align-items: center;
      background-color: #ebeced;
      background-color: rgba(235, 236, 237, 0.25);
      border-radius: 10px;
      padding: 11px 20px;
      transition: all 0.4s ease;
      @media (max-width: 1199px) {
        padding: 11px 15px;
      }
      &:hover {
        background-color: rgba(235, 236, 237, 0.8);
      }
      &:not(:last-child) {
        margin-bottom: 15px;
      }
    }
    span {
      display: flex;
      align-items: center;
      gap: 8px;
      svg {
        color: var(--accent-color);
      }
    }
  }
  .td_card_video_block {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    .td_player_btn_wrap_2 {
      position: absolute;
      left: 50%;
      top: 50%;
      transform: translate(-50%, -50%);
      margin: 0;
      .td_player_btn {
        color: var(--accent-color);
        &::after {
          background-color: #fff;
        }
      }
    }
  }
}
